#encoding=utf-8
'''
Created on 2018-5-23

@author: cooler
'''

#权限列表，对不同用户给与不同权限
#权限分为5类
#1 超级管理员权限，全部页面均可查看操作
#2 产品经理
#3 运营经理
#4 数据分析师
#5 其他
from flask_principal import RoleNeed, Permission

all_permission = Permission(RoleNeed('admin'),RoleNeed('product'),RoleNeed('operation'),RoleNeed('data_analyst'),RoleNeed('other'))
product_permission = Permission(RoleNeed('admin'),RoleNeed('product'))
operation_permission = Permission(RoleNeed('admin'),RoleNeed('operation'))
data_analyst_permission = Permission(RoleNeed('admin'),RoleNeed('data_analyst'))
other_permission = Permission(RoleNeed('admin'),RoleNeed('other'))
admin_permission = Permission(RoleNeed('admin'))
